1. Technical Field:
The present invention relates in general to data storage management in data processing systems and in particular to coherency state and LRU position information maintained for data storage management. Still more particularly, the present invention relates to altering cache coherency states and/or LRU positions in response to related data access and cast out or deallocate operations in a data processing system.
2. Description of the Related Art:
High performance data processing systems typically include a number of levels of caching between the processor(s) and system memory to improve performance, reducing latency in data access operations. When utilized, multiple cache levels are typically employed in progressively larger sizes with a trade off to progressively longer access latencies. Smaller, faster caches are employed at levels within the storage hierarchy closer to the processor or processors, while larger, slower caches are employed at levels closer to system memory. Smaller amounts of data are maintained in upper cache levels, but may be accessed faster.
Within such systems, when data access operations frequently give rise to a need to make space for the subject data. For example, when retrieving data from lower storage levels such as system memory or lower level caches, a cache may need to overwrite other data already within the cache because no further unused space is available for the retrieved data. A replacement policyxe2x80x94typically a least-recently-used (LRU) replacement policyxe2x80x94is employed to decide which cache location(s) should be utilized to store the new data.
Often the cache location (commonly referred to as a xe2x80x9cvictimxe2x80x9d) to be overwritten contains only data which is invalid or otherwise unusable from the perspective of a memory coherency model being employed, or for which valid copies are concurrently stored in other devices within the system storage hierarchy. In such cases, the new data may be simply written to the cache location without regard to preserving the existing data at that location.
At other times, however, the cache location selected to received the new data contains modified data, or data which is otherwise unique or special within the storage hierarchy.
In such instances, the replacement of data within a selected cache location (a process often referred to as xe2x80x9cupdatingxe2x80x9d the cache) requires that any modified data associated with the cache location selected by the replacement policy be written back to lower levels of the storage hierarchy for preservation. The process of writing modified data from a victim to system memory or a lower cache level is generally called a cast out or eviction.
When a cache initiates a data access operationxe2x80x94for instance, in response to a cache miss for a READ operation originating with a processorxe2x80x94typically the cache will initiate a data access operation (READ or WRITE) on a bus coupling the cache to lower storage levels. If the replacement policy requires that a modified cache line be over-written, compelling a cast out for coherency purposes, the cache will also initiate the cast out bus operation.
Even when the selected victim contains data which is neither unique nor special within the storage hierarchy (i.e. invalid data), an operation to lower levels of the storage hierarchy may still be required. For instance, the cache organization may be xe2x80x9cinclusive,xe2x80x9d meaning that logically vertical in-line caches contain a common data set. xe2x80x9cPrecisexe2x80x9d inclusivity requires that lower level caches include at least all cache lines contained within a vertically in-line, higher level cache, although the lower level cache may include additional cache lines as well. Imprecise or xe2x80x9cpseudo-precisexe2x80x9d inclusivity relaxes this requirement, but still seeks to have as much of the data within the higher level cache copied within the lower level cache as possible within constraints imposed by bandwidth utilization tradeoffs. Within an inclusive, hierarchical cache system, even if the cache line to be replaced is in a coherency state (e.g., xe2x80x9csharedxe2x80x9d) indicating that the data may be simple discarded without writing it to lower level storage, an operation to the lower level storage may be required to update inclusivity information. The storage device within which the cache line is to be overwritten (or xe2x80x9cdeallocatedxe2x80x9d and replaced) initiates an operation notifying lower level, in-line storage devices of the deallocation, so that the lower level devices may update internal inclusivity information associated with the cache line. This requires an operation in addition to the data access operation necessitating replacement of the cache line.
The data access and cast out/deallocate bus operations represent opportunities for global data storage management. In particular, the coherency state and LRU position of the cast out or deallocate victim in horizontal storage devices may be updated based on the change in the storage device initiating the data access and cast out/deallocate operations. However, due to the disjoint nature of the related operations in the prior art, such opportunities are not generally exploited. Additionally, a lack of sufficient information from other horizontal storage devices may prevent exploitation of data storage management opportunities in related data access and replacement operations.
It would be desirable, therefore, to take advantage of data storage management opportunities represented by related data access and cast out or deallocate bus operations. It would further be advantageous to support alteration of coherency state and/or LRU position information for cast out or deallocate victims in horizontal storage devices.
It is therefore one object of the present invention to provide improved data storage management in data processing systems.
It is another object of the present invention to provide improved management of coherency state and LRU position information maintained for data storage.
It is yet another object of the present invention to provide alteration of cache coherency states and LRU positions in response to related data access and cast out or deallocate operations in a data processing system.
The foregoing objects are achieved as is now described. Combined response logic for a bus receives a combined data access and cast out/deallocate operation initiating by a storage device within a specific level of a storage hierarchy, with a coherency state and LRU position of the cast out/deallocate victim appended. Snoopers on the bus drive snoop responses to the combined operation with the coherency state and/or LRU position of locally-stored cache lines corresponding to the victim appended. The combined response logic determines, from the coherency state and LRU position information appended to the combined operation and the snoop responses, whether an update of the LRU position and/or coherency state of a cache line corresponding to the victim within one of the snoopers is required. If so, the combined response logic selects a snooper storage device to have at least the LRU position of a respective cache line corresponding to the victim updated, and appends an update command identifying the selected snooper to the combined response. The snooper selected to be updated may be randomly chosen, selected based on LRU position of the cache line corresponding to the victim within respective storage, or selected based on other criteria.
The above as well as additional objects, features, and advantages of the present invention will become apparent in the following detailed written description.